package com.efast.cafe.commponent.statemach.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.efast.cafe.commponent.statemach.bean.StateMachResourceTask;
import com.efast.cafe.commponent.statemach.dao.PortalStateMachResourceTaskDao;
import com.efast.cafe.commponent.statemach.service.IPortalStateMachResourceTaskService;
@Service
@Transactional
public class PortalStateMachResourceTaskServiceImpl implements IPortalStateMachResourceTaskService{

	@Autowired
	private PortalStateMachResourceTaskDao stateMachResourceTaskDao;
	
	@Override
	public void insertResourceTask(StateMachResourceTask ResourceTask) {
		stateMachResourceTaskDao.insertResourceTask(ResourceTask);
	}

	@Override
	public void updateResourceTask(StateMachResourceTask ResourceTask) {
		stateMachResourceTaskDao.updateResourceTask(ResourceTask);
	}

	@Override
	public void deleteResourceTask(StateMachResourceTask ResourceTask) {
		stateMachResourceTaskDao.deleteResourceTask(ResourceTask);
	}

	@Override
	public StateMachResourceTask getResourceTaskByIdAndName(Long taskId, String ObjectName) {
		return stateMachResourceTaskDao.getResourceTaskByIdAndName(taskId, ObjectName);
	}

	@Override
	public List<StateMachResourceTask> getResourceTaskListByIdAndName(Long taskId, String ObjectName) {
		return stateMachResourceTaskDao.getResourceTaskListByIdAndName(taskId, ObjectName);
	}

	@Override
	public List<StateMachResourceTask> getStateMachResourceTaskListByTaskId(Long taskId) {
		return stateMachResourceTaskDao.getStateMachResourceTaskListByTaskId(taskId);
	}

	@Override
	public void deleteResourceTaskByTaskId(Long taskId, String objName) {
		stateMachResourceTaskDao.deleteResourceTaskByTaskId(taskId, objName);
	}
	
}
